<h3 class="page-title">站点媒体查询</h3>

<div class="portlet">
	<div class="portlet-title">
              <div class="title-blank">
              	<span ng-repeat="media in mediaTypes" style="margin-right: 15px;">
              		<input type="radio" name="mediaType" ng-checked="media.mediaId == mediaResourceGrid.mediaType" style="position: static;margin: 0px;" ng-click="mediaResourceGrid.initDynamicTable(media.mediaId,media.modelType)">
              		{{media.mediaName}}
              	</span>
              </div>
              <a href="javascript:void(0);" class="title-operation search-expand">筛选</a>
		<div class="title-search-box">
			<input type="text" placeholder="请输入站点名称" class="search-field" ng-model="mediaResourceGrid.query.stopName"
				style="width: 180px;" maxlength="100">
			<a class="fa fa-search" ng-click="mediaResourceGrid.initDynamicTable(mediaResourceGrid.mediaType,mediaResourceGrid.modelType);"></a>
		</div>
	</div>
	<div class="portlet-search-body" style="display: none">
			<form class="form-horizontal" role="form" style="margin: 2px;">
				 <div class="form-body">
                      	<div class="row" style="margin-bottom: 5px;">
                      		<div class="col-md-2">
                                  <div class="input-icon">
                                   	<i class="fa fa-lightbulb-o"></i>
								<input class="form-control" placeholder="站点名称" ng-model="mediaResourceGrid.query.stopName">
                                  </div>
                              </div>
                              <div class="col-md-2">
                                  <div class="input-icon">
                                     	<i class="fa fa-lightbulb-o"></i>
								<input class="form-control" placeholder="街道" ng-model="mediaResourceGrid.query.roadName">
                                  </div>
                              </div>
                              <div class="col-md-2">
                                  <div class="input-icon">
                                     	<i class="fa fa-lightbulb-o"></i>
								<select class="form-control" style="width: 200px;color: #b3b3b3;" ng-model="mediaResourceGrid.query.county" ng-options="opt.value as opt.name for opt in options.AREA_COUNTY">
                                          <option value="" >行政区划</option>
								</select>
                                  </div>
                              </div>
                              <div class="col-md-2">
                                  <div class="input-icon">
                                     	<i class="fa fa-bus"></i>
                                     	<select class="form-control" style="color: #b3b3b3;" ng-model="mediaResourceGrid.query.customerId" ng-options="opt.customerId as opt.customerName for opt in customerList">
                                     		<option value="" >经营单位 </option>
										</select>
                                  </div>
                              </div>
								<div class="col-md-2">
									<div class="input-icon">
										<i class="fa fa-bus"></i>
										<input class="form-control" placeholder="合同号" ng-model="mediaResourceGrid.query.contractNo">
									</div>
								</div>
								<div class="col-md-2">
									<div class="input-icon">
										<i class="fa fa-lightbulb-o"></i>
										<input class="form-control" placeholder="广告内容" ng-model="mediaResourceGrid.query.content"
											   ng-show="mediaResourceGrid.modelType != undefined && mediaResourceGrid.modelType != '' && mediaResourceGrid.modelType == '1'">
									</div>
								</div>
                              <div class="col-md-2">
                                  <div class="input-icon" ng-style="{'padding-top': mediaResourceGrid.modelType == '1' ? '5px' : '0' }">
										<button class="btn btn-primary" ng-click="mediaResourceGrid.initDynamicTable(mediaResourceGrid.mediaType,mediaResourceGrid.modelType);">
											<i class="fa fa-search"></i> 搜索
										</button>
										<button class="btn btn-primary" ng-click="reset()">
										  <i class="fa fa-rotate-left"></i> 重置
										</button>
                                  </div>
                              </div>
                      	</div>
				 </div>
                             
                      
			</form>
	</div>
	<div class="portlet-body">
		<div ed-grid-dynamic="mediaResourceGrid" ed-url="media/resource/stop/query.do" style="width: 100%;"></div>
	</div>
</div>

<div ed-modal="resourceInfoModal" data-options="title:'资源历史',icon:'fa-bus',static:true,width:'900px',defaultButton:false">
    <div style="padding: 5px;width: 100%;overflow: auto;height:500px;">
		<div class="portlet">
			<div class="portlet-body">
				<tabset>
					<tab heading="广告刊载">
			            <div class="portlet">
			            	<div class="portlet-body">
								<table ed-grid="resourceAdsGrid" ed-url="media/resource/ads.do"class="table table-striped table-bordered table-hover dataTable" style="width: 100%;">
									<thead>
						                <tr>
						                    <th ed-data="_index"></th>
						                    <th ed-data="content">广告内容</th>
						                    <th ed-data="customerName">经营单位</th>
											<th ed-data="billNo">上刊单号</th>
						                    <!--<th ed-data="publishTime">广告起始时间</th>-->
						                    <!--<th ed-data="publishOffTime">广告终止时间</th>-->
						                </tr>
						            </thead>
								</table>
							</div>
			            </div>
			        </tab>
					<tab heading="经营权属">
			            <div class="portlet">
			            	<div class="portlet-body">
								<table ed-grid="resourceRightsGrid" ed-url="media/resource/rights.do" class="table table-striped table-bordered table-hover dataTable" style="width: 100%;">
									<thead>
						                <tr>
						                    <th ed-data="_index"></th>
						                    <th ed-data="contractNo">合同编号</th>
						                    <th ed-data="customerName">经营单位</th>
						                    <th ed-data="startDate">经营起始时间</th>
						                    <th ed-data="endDate">经营终止时间</th>
						                </tr>
						            </thead>
								</table>
							</div>
			            </div>
			        </tab>

					<tab heading="资源详情">
						<div class="portlet">
							<div class="portlet-body">
								<table  class="table table-striped table-bordered table-hover dataTable" style="width: 70%;margin-left: 16%;">
									<thead>
									<tr>
										<th style="text-align: center;width: 30%">数据项</th>
										<th style="text-align: center;width: 70%">数据值</th>
									</tr>
									</thead>
									<tbody>
									<tr ng-repeat="item in resourceItemHead" style="text-align: center">
										<td>{{item.name}}</td>

										<td ng-show="item.type == 'STRING' || !item.type" ng-style="{'border-bottom':'1px solid #ddd','border-right':'none'}">{{resourceItemData[item.col]}}</td>
										<td ng-show="item.type == 'CODE'" >{{resourceItemData[item.col] | code : item.code }} </td>
										<td ng-show="item.type == 'showImg' && {{resourceItemData[item.col] != undefined && resourceItemData[item.col] != ''}}" style="border-top: 0px;">
											<div class="mix-grid" style="display: block;">
						                    	<div class="mix" style="display: inline-block;opacity: 1;padding-right: 5px;">
						                    		<div class="mix-inner">
														<img class="img-responsive" ng-src="{{nginxPath + resourceItemData[item.col]}}" style="width:150px;height:120px">
														<div class="mix-details" style="height:50%;">
															<a class="mix-preview fancybox-button"  style="position: static;display: inline-block;" ng-href="{{nginxPath+resourceItemData[item.col]}}" data-rel="fancybox-button">
																<i class="fa fa-search"></i>
															</a>
														</div>
													</div>
												</div>
											</div>
										</td>
									</tr>
									</tbody>
								</table>
							</div>
						</div>
					</tab>

			    </tabset>
			</div>
		</div>
    </div>
</div>


<div ed-modal="stopPointsModal" data-options="title:'站点定位',icon:'fa-bus',static:true,width:'900px',defaultButton:false">
	<div id="stopPointsModalMapDiv" style="overflow: auto;height: 500px;width: 100%;">
                   
	</div>
</div>

<div ed-modal="stopMediaInfoModal" data-options="title:'站点信息',icon:'icon-direction',static:true,width:'900px',defaultButton:false">
        <div class="form" style="overflow: auto;height: 500px;">
             <form action="#" class="form-horizontal form-row-seperated w5c-form">
                        <div class="form-body">
                        	<div class="row">
                        		<div class="col-md-12">
	                        		<div class="form-group">
	                                	<label class="col-md-2 control-label">站点名称：</label>
		                                <div class="col-md-4">
		                                	<p class='form-control-static'>{{mediaStop.stopName}}</p>
		                                </div>
		                                <label class="col-md-2 control-label">行政区划：</label>
		                                <div class="col-md-4">
		                                	<p class='form-control-static'>{{mediaStop.county | code:'AREA_COUNTY'}}</p>
		                                </div>
	                            	</div>
                        		</div>
                        	</div>
                        	<div class="row">
                        		<div class="col-md-12">
	                        		<div class="form-group">
	                                	<label class="col-md-2 control-label">所在街道：</label>
		                                <div class="col-md-4">
		                                	<p class='form-control-static'>{{mediaStop.roadName}}</p>
		                                </div>
		                                <label class="col-md-2 control-label">行　　向：</label>
		                                <div class="col-md-4">
		                                	<p class='form-control-static'>{{mediaStop.direction}}</p>
		                                </div>
	                            	</div>
                        		</div>
                        	</div>

							<div class="row">
								<div class="col-md-12">
									<div class="form-group">
										<label class="col-md-2 control-label">级　　别：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.mediaLevel | code:'RESOURCE_LEVEL'}}</p>
										</div>
										<label class="col-md-2 control-label">副&nbsp; 站&nbsp;名：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.deputyStopName}}</p>
										</div>
									</div>
								</div>
							</div>

							<div class="row">
								<div class="col-md-12">
									<div class="form-group">
										<label class="col-md-2 control-label">经过线路：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.passLines}}</p>
										</div>
										<label class="col-md-2 control-label">维护单位：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.maintenanceCompany}}</p>
										</div>
									</div>
								</div>
							</div>

							<div class="row">
								<div class="col-md-12">
									<div class="form-group">
										<label class="col-md-2 control-label">站杆样式：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.zgStyle}}</p>
										</div>
										<label class="col-md-2 control-label" style="padding-left: 0px;">候车厅设施种类：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.hctssType}}</p>
										</div>
									</div>
								</div>
							</div>

							<div class="row">
								<div class="col-md-12">
									<div class="form-group">
										<label class="col-md-2 control-label">亮灯情况：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.ldSituation}}</p>
										</div>
										<label class="col-md-2 control-label">站牌接电情况：</label>
										<div class="col-md-4">
											<p class='form-control-static'>{{mediaStop.zpjdSituation}}</p>
										</div>
									</div>
								</div>
							</div>
                        	<div class="row">
                        		<div class="col-md-12">
	                        		<div class="form-group">
	                                	<label class="col-md-2 control-label">环境标签：</label>
		                                <div class="col-md-9">
		                                	<p class='form-control-static'>
		                                		<span ng-repeat="mark in mediaStop.marks" style="background-color: gray;padding: 2px 5px;color: white;margin-right: 10px;">{{mark.markName}}</span>
		                                	</p>
		                                </div>
	                            	</div>
                        		</div>
                        	</div>
                        	<div class="row">
                        		<div class="col-md-12">
	                        		<div class="form-group">
	                                	<label class="col-md-2 control-label">照　　片： </label>
		                                <div class="col-md-10">
		                                	<div class="mix-grid" style="display: inline;" ng-repeat="img in mediaStop.stopImgs">
						                    	<div class="mix" style="display: inline-block;opacity: 1;padding-right: 5px;">
						                    		<div class="mix-inner">
														<img class="img-responsive" ng-src="{{nginxPath+img.path}}" alt="" style="width:150px;height:120px">
														<div class="mix-details" style="height:50%;">
															<a class="mix-preview fancybox-button" style="position: static;display: inline-block;" ng-href="{{nginxPath+img.path}}" data-rel="fancybox-button">
																<i class="fa fa-search"></i>
															</a>
														</div>
													</div>
												</div>
											</div> 
		                                </div>
	                            	</div>
                        		</div>
                        	</div>
                        </div>
                    </form>
            </div>
	</div>




